package jtk.project4.fleet.ibatis.dao;

import java.sql.SQLException;
import java.util.List;

import jtk.project4.fleet.domain.RbDept;



public class RbDeptDao extends IbatisDao{
		
		public List selectRbDept() throws SQLException {
			List selectRbDept = null;
				selectRbDept =getSqlMap().queryForList("SELECT_ALL_RbDept", null);
			return selectRbDept;
		}

		public int deleteRbDept(RbDept rbdept) throws SQLException{
			return (int) getSqlMap().delete("DELETE_RbDept", rbdept);
		}
		
		public int updateRbDept(RbDept rbdept) throws SQLException{
			return (int) getSqlMap().update("UPDATE_RbDept", rbdept);
		}
		
		public RbDept insertRbDept(RbDept rbdept) throws SQLException{
			return (RbDept) getSqlMap().insert("INSERT_RbDept", rbdept);
		}
			
		public static void main (String args[]) throws SQLException{
			RbDept rbdept;
			rbdept = new RbDept();
			rbdept.setDeptId(3);
			new RbDeptDao().deleteRbDept(rbdept);
			}
		
	}


